import { createApp } from 'vue';
import { createPinia } from 'pinia';

import App from './App.vue';
import { useRouter } from '@code4x/layout';
import router from '@/router';
import guards from '@/router/guards';

// 整合svg图标
import 'virtual:svg-icons-register';
// main.ts
// import '@unocss/reset/tailwind-compat.css'; // Tailwind 兼容，避免与ui框架冲突
import '@unocss/reset/normalize.css';
import 'virtual:uno.css';

import '@/styles/styles.scss';
// import naive from 'naive-ui';
const app = createApp(App);

// naiveDiscreteApi()
// app.use(naive);
app.use(createPinia());
useRouter({
  app,
  router,
  guards,
  appName: import.meta.env.VITE_GLOB_APP_TITLE,
});
app.mount('#app');
